﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Commerce.Base.Ubl.DataType
{
    /// <summary>
    /// A list of two mutually exclusive Boolean values that express the only possible states of a property.
    /// </summary>
    public class Indicator
    {
        private System.Boolean value;

        /// <summary>
        /// The indicator value.
        /// </summary>
        public System.Boolean Value
        {
            get { return this.value; }
            set { this.value = value; }
        }

        public Indicator(System.Boolean value)
        {
            this.value = value;
        }

        public override string ToString()
        {
            return this.value.ToString();
        }

        public static implicit operator Indicator(System.Boolean value)
        {
            return new Indicator(value);
        }

        public static implicit operator System.Boolean(Indicator indicator)
        {
            return indicator.value;
        }
    }
}
